<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>清除内外边距</title>
    <style>
        /* 这句话也是css的第一行代码 */
        * {
            margin: 0;
            padding: 0;
        }
        span {
            background-color: aqua;
            margin: 20px;
        }
    </style>
</head>
<body>
    123
    <ul>
        <li>abcd</li>
    </ul>
    <span>行内块元素尽量只设置左右内外边距</span><br>
    <img src="img/清除内外边距.png" alt="">
</body>
</html>